<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html xmlns:yui="http://yuilibrary.com/rdf/1.0/yui.rdf#">
<head>
    <meta http-equiv="content-type" content="text/html; charset=UTF-8" />
	<title>API: datasource   Type.js  (YUI Library)</title>

	<link rel="stylesheet" type="text/css" href="assets/reset-fonts-grids-min.css" />
	<link rel="stylesheet" type="text/css" href="assets/api.css" />

    <script type="text/javascript" src="assets/api-js"></script>
    <script type="text/javascript" src="assets/ac-js"></script>
</head>

<body id="yahoo-com">

<div id="doc3" class="yui-t2">
	<div id="hd">
        <h1><a href="http://developer.yahoo.com/yui/" title="Yahoo! UI Library">Yahoo! UI Library</a></h1>
        <h3>DataSource Utility&nbsp; <span class="subtitle">2.9.0</span></h3>
        <a href="./index.html" title="Yahoo! UI Library">Yahoo! UI Library</a> 
            &gt; <a href="./module_datasource.html" title="datasource">datasource</a>
                
                 &gt; Type.js (source view) 
        <form onsubmit="return false">
            <div id="propertysearch">
                Search: <input autocomplete="off" id="searchinput" />
                <div id="searchresults">
                    &nbsp;
                </div>
            </div>
        </form>
	</div>

	<div id="bd">
		<div id="yui-main">
			<div class="yui-b">
            <form action="#" name="yui-classopts-form" method="get" id="yui-classopts-form">
                <fieldset>
                    <legend>Filters</legend>
                <span class="classopts"><input type="checkbox" name="show_private" id="show_private" /> <label for="show_private">Show Private</label></span>
                <span class="classopts"><input type="checkbox" name="show_protected" id="show_protected" /> <label for="show_protected">Show Protected</label></span>
                <span class="classopts"><input type="checkbox" name="show_deprecated" id="show_deprecated" /> <label for="show_deprecated">Show Deprecated</label></span>
                </fieldset>
            </form>

                    <div id="srcout">
                        <style>
                            #doc3 .classopts { display:none; }
                        </style>
                        <div class="highlight"><pre><span class="cm">/****************************************************************************/</span>
<span class="cm">/****************************************************************************/</span>
<span class="cm">/****************************************************************************/</span>

<span class="cm">/**</span>
<span class="cm"> * The static Number class provides helper functions to deal with data of type</span>
<span class="cm"> * Number.</span>
<span class="cm"> *</span>
<span class="cm"> * @namespace YAHOO.util</span>
<span class="cm"> * @requires yahoo</span>
<span class="cm"> * @class Number</span>
<span class="cm"> * @static</span>
<span class="cm"> */</span>
 <span class="nx">YAHOO</span><span class="p">.</span><span class="nx">util</span><span class="p">.</span><span class="nb">Number</span> <span class="o">=</span> <span class="p">{</span>
 
     <span class="cm">/**</span>
<span class="cm">     * Takes a native JavaScript Number and formats to a string for display.</span>
<span class="cm">     *</span>
<span class="cm">     * @method format</span>
<span class="cm">     * @param nData {Number} Number.</span>
<span class="cm">     * @param oConfig {Object} (Optional) Optional configuration values:</span>
<span class="cm">     *  &lt;dl&gt;</span>
<span class="cm">     *   &lt;dt&gt;format&lt;/dt&gt;</span>
<span class="cm">     *   &lt;dd&gt;String used as a template for formatting positive numbers.</span>
<span class="cm">     *   {placeholders} in the string are applied from the values in this</span>
<span class="cm">     *   config object. {number} is used to indicate where the numeric portion</span>
<span class="cm">     *   of the output goes.  For example &amp;quot;{prefix}{number} per item&amp;quot;</span>
<span class="cm">     *   might yield &amp;quot;$5.25 per item&amp;quot;.  The only required</span>
<span class="cm">     *   {placeholder} is {number}.&lt;/dd&gt;</span>
<span class="cm">     *</span>
<span class="cm">     *   &lt;dt&gt;negativeFormat&lt;/dt&gt;</span>
<span class="cm">     *   &lt;dd&gt;Like format, but applied to negative numbers.  If set to null,</span>
<span class="cm">     *   defaults from the configured format, prefixed with -.  This is</span>
<span class="cm">     *   separate from format to support formats like &amp;quot;($12,345.67)&amp;quot;.</span>
<span class="cm">     *</span>
<span class="cm">     *   &lt;dt&gt;prefix {String} (deprecated, use format/negativeFormat)&lt;/dt&gt;</span>
<span class="cm">     *   &lt;dd&gt;String prepended before each number, like a currency designator &quot;$&quot;&lt;/dd&gt;</span>
<span class="cm">     *   &lt;dt&gt;decimalPlaces {Number}&lt;/dt&gt;</span>
<span class="cm">     *   &lt;dd&gt;Number of decimal places to round.&lt;/dd&gt;</span>
<span class="cm">     *</span>
<span class="cm">     *   &lt;dt&gt;decimalSeparator {String}&lt;/dt&gt;</span>
<span class="cm">     *   &lt;dd&gt;Decimal separator&lt;/dd&gt;</span>
<span class="cm">     *</span>
<span class="cm">     *   &lt;dt&gt;thousandsSeparator {String}&lt;/dt&gt;</span>
<span class="cm">     *   &lt;dd&gt;Thousands separator&lt;/dd&gt;</span>
<span class="cm">     *</span>
<span class="cm">     *   &lt;dt&gt;suffix {String} (deprecated, use format/negativeFormat)&lt;/dt&gt;</span>
<span class="cm">     *   &lt;dd&gt;String appended after each number, like &quot; items&quot; (note the space)&lt;/dd&gt;</span>
<span class="cm">     *  &lt;/dl&gt;</span>
<span class="cm">     * @return {String} Formatted number for display. Note, the following values</span>
<span class="cm">     * return as &quot;&quot;: null, undefined, NaN, &quot;&quot;.</span>
<span class="cm">     */</span>
    <span class="nx">format</span> <span class="o">:</span> <span class="kd">function</span><span class="p">(</span><span class="nx">n</span><span class="p">,</span> <span class="nx">cfg</span><span class="p">)</span> <span class="p">{</span>
        <span class="k">if</span> <span class="p">(</span><span class="nx">n</span> <span class="o">===</span> <span class="s1">&#39;&#39;</span> <span class="o">||</span> <span class="nx">n</span> <span class="o">===</span> <span class="kc">null</span> <span class="o">||</span> <span class="o">!</span><span class="nb">isFinite</span><span class="p">(</span><span class="nx">n</span><span class="p">))</span> <span class="p">{</span>
            <span class="k">return</span> <span class="s1">&#39;&#39;</span><span class="p">;</span>
        <span class="p">}</span>

        <span class="nx">n</span>   <span class="o">=</span> <span class="o">+</span><span class="nx">n</span><span class="p">;</span>
        <span class="nx">cfg</span> <span class="o">=</span> <span class="nx">YAHOO</span><span class="p">.</span><span class="nx">lang</span><span class="p">.</span><span class="nx">merge</span><span class="p">(</span><span class="nx">YAHOO</span><span class="p">.</span><span class="nx">util</span><span class="p">.</span><span class="nb">Number</span><span class="p">.</span><span class="nx">format</span><span class="p">.</span><span class="nx">defaults</span><span class="p">,</span> <span class="p">(</span><span class="nx">cfg</span> <span class="o">||</span> <span class="p">{}));</span>

        <span class="kd">var</span> <span class="nx">stringN</span> <span class="o">=</span> <span class="nx">n</span><span class="o">+</span><span class="s1">&#39;&#39;</span><span class="p">,</span>
            <span class="nx">absN</span>   <span class="o">=</span> <span class="nb">Math</span><span class="p">.</span><span class="nx">abs</span><span class="p">(</span><span class="nx">n</span><span class="p">),</span>
            <span class="nx">places</span> <span class="o">=</span> <span class="nx">cfg</span><span class="p">.</span><span class="nx">decimalPlaces</span> <span class="o">||</span> <span class="mi">0</span><span class="p">,</span>
            <span class="nx">sep</span>    <span class="o">=</span> <span class="nx">cfg</span><span class="p">.</span><span class="nx">thousandsSeparator</span><span class="p">,</span>
            <span class="nx">negFmt</span> <span class="o">=</span> <span class="nx">cfg</span><span class="p">.</span><span class="nx">negativeFormat</span> <span class="o">||</span> <span class="p">(</span><span class="s1">&#39;-&#39;</span> <span class="o">+</span> <span class="nx">cfg</span><span class="p">.</span><span class="nx">format</span><span class="p">),</span>
            <span class="nx">s</span><span class="p">,</span> <span class="nx">bits</span><span class="p">,</span> <span class="nx">i</span><span class="p">,</span> <span class="nx">precision</span><span class="p">;</span>

        <span class="k">if</span> <span class="p">(</span><span class="nx">negFmt</span><span class="p">.</span><span class="nx">indexOf</span><span class="p">(</span><span class="s1">&#39;#&#39;</span><span class="p">)</span> <span class="o">&gt;</span> <span class="o">-</span><span class="mi">1</span><span class="p">)</span> <span class="p">{</span>
            <span class="c1">// for backward compatibility of negativeFormat supporting &#39;-#&#39;</span>
            <span class="nx">negFmt</span> <span class="o">=</span> <span class="nx">negFmt</span><span class="p">.</span><span class="nx">replace</span><span class="p">(</span><span class="sr">/#/</span><span class="p">,</span> <span class="nx">cfg</span><span class="p">.</span><span class="nx">format</span><span class="p">);</span>
        <span class="p">}</span>

        <span class="k">if</span> <span class="p">(</span><span class="nx">places</span> <span class="o">&lt;</span> <span class="mi">0</span><span class="p">)</span> <span class="p">{</span>
            <span class="c1">// Get rid of the decimal info</span>
            <span class="nx">s</span> <span class="o">=</span> <span class="nx">absN</span> <span class="o">-</span> <span class="p">(</span><span class="nx">absN</span> <span class="o">%</span> <span class="mi">1</span><span class="p">)</span> <span class="o">+</span> <span class="s1">&#39;&#39;</span><span class="p">;</span>
            <span class="nx">i</span> <span class="o">=</span> <span class="nx">s</span><span class="p">.</span><span class="nx">length</span> <span class="o">+</span> <span class="nx">places</span><span class="p">;</span>

            <span class="c1">// avoid 123 vs decimalPlaces -4 (should return &quot;0&quot;)</span>
            <span class="k">if</span> <span class="p">(</span><span class="nx">i</span> <span class="o">&gt;</span> <span class="mi">0</span><span class="p">)</span> <span class="p">{</span>
                <span class="c1">// leverage toFixed by making 123 =&gt; 0.123 for the rounding</span>
                <span class="c1">// operation, then add the appropriate number of zeros back on</span>
                <span class="nx">s</span> <span class="o">=</span> <span class="nb">Number</span><span class="p">(</span><span class="s1">&#39;.&#39;</span> <span class="o">+</span> <span class="nx">s</span><span class="p">).</span><span class="nx">toFixed</span><span class="p">(</span><span class="nx">i</span><span class="p">).</span><span class="nx">slice</span><span class="p">(</span><span class="mi">2</span><span class="p">)</span> <span class="o">+</span>
                    <span class="k">new</span> <span class="nb">Array</span><span class="p">(</span><span class="nx">s</span><span class="p">.</span><span class="nx">length</span> <span class="o">-</span> <span class="nx">i</span> <span class="o">+</span> <span class="mi">1</span><span class="p">).</span><span class="nx">join</span><span class="p">(</span><span class="s1">&#39;0&#39;</span><span class="p">);</span>
            <span class="p">}</span> <span class="k">else</span> <span class="p">{</span>
                <span class="nx">s</span> <span class="o">=</span> <span class="s2">&quot;0&quot;</span><span class="p">;</span>
            <span class="p">}</span>
        <span class="p">}</span> <span class="k">else</span> <span class="p">{</span>
            <span class="c1">// Avoid toFixed on floats:</span>
            <span class="c1">// Bug 2528976</span>
            <span class="c1">// Bug 2528977</span>
            <span class="kd">var</span> <span class="nx">unfloatedN</span> <span class="o">=</span> <span class="nx">absN</span><span class="o">+</span><span class="s1">&#39;&#39;</span><span class="p">;</span>
            <span class="k">if</span><span class="p">(</span><span class="nx">places</span> <span class="o">&gt;</span> <span class="mi">0</span> <span class="o">||</span> <span class="nx">unfloatedN</span><span class="p">.</span><span class="nx">indexOf</span><span class="p">(</span><span class="s1">&#39;.&#39;</span><span class="p">)</span> <span class="o">&gt;</span> <span class="mi">0</span><span class="p">)</span> <span class="p">{</span>
                <span class="kd">var</span> <span class="nx">power</span> <span class="o">=</span> <span class="nb">Math</span><span class="p">.</span><span class="nx">pow</span><span class="p">(</span><span class="mi">10</span><span class="p">,</span> <span class="nx">places</span><span class="p">);</span>
                <span class="nx">s</span> <span class="o">=</span> <span class="nb">Math</span><span class="p">.</span><span class="nx">round</span><span class="p">(</span><span class="nx">absN</span> <span class="o">*</span> <span class="nx">power</span><span class="p">)</span> <span class="o">/</span> <span class="nx">power</span> <span class="o">+</span> <span class="s1">&#39;&#39;</span><span class="p">;</span>
                <span class="kd">var</span> <span class="nx">dot</span> <span class="o">=</span> <span class="nx">s</span><span class="p">.</span><span class="nx">indexOf</span><span class="p">(</span><span class="s1">&#39;.&#39;</span><span class="p">),</span>
                    <span class="nx">padding</span><span class="p">,</span> <span class="nx">zeroes</span><span class="p">;</span>
                
                <span class="c1">// Add padding</span>
                <span class="k">if</span><span class="p">(</span><span class="nx">dot</span> <span class="o">&lt;</span> <span class="mi">0</span><span class="p">)</span> <span class="p">{</span>
                    <span class="nx">padding</span> <span class="o">=</span> <span class="nx">places</span><span class="p">;</span>
                    <span class="nx">zeroes</span> <span class="o">=</span> <span class="p">(</span><span class="nb">Math</span><span class="p">.</span><span class="nx">pow</span><span class="p">(</span><span class="mi">10</span><span class="p">,</span> <span class="nx">padding</span><span class="p">)</span> <span class="o">+</span> <span class="s1">&#39;&#39;</span><span class="p">).</span><span class="nx">substring</span><span class="p">(</span><span class="mi">1</span><span class="p">);</span>
                    <span class="k">if</span><span class="p">(</span><span class="nx">places</span> <span class="o">&gt;</span> <span class="mi">0</span><span class="p">)</span> <span class="p">{</span>
                        <span class="nx">s</span> <span class="o">=</span> <span class="nx">s</span> <span class="o">+</span> <span class="s1">&#39;.&#39;</span> <span class="o">+</span> <span class="nx">zeroes</span><span class="p">;</span>
                    <span class="p">}</span>
                <span class="p">}</span>
                <span class="k">else</span> <span class="p">{</span>
                    <span class="nx">padding</span> <span class="o">=</span> <span class="nx">places</span> <span class="o">-</span> <span class="p">(</span><span class="nx">s</span><span class="p">.</span><span class="nx">length</span> <span class="o">-</span> <span class="nx">dot</span> <span class="o">-</span> <span class="mi">1</span><span class="p">);</span>
                    <span class="nx">zeroes</span> <span class="o">=</span> <span class="p">(</span><span class="nb">Math</span><span class="p">.</span><span class="nx">pow</span><span class="p">(</span><span class="mi">10</span><span class="p">,</span> <span class="nx">padding</span><span class="p">)</span> <span class="o">+</span> <span class="s1">&#39;&#39;</span><span class="p">).</span><span class="nx">substring</span><span class="p">(</span><span class="mi">1</span><span class="p">);</span>
                    <span class="nx">s</span> <span class="o">=</span> <span class="nx">s</span> <span class="o">+</span> <span class="nx">zeroes</span><span class="p">;</span>
                <span class="p">}</span>
            <span class="p">}</span>
            <span class="k">else</span> <span class="p">{</span>
                <span class="nx">s</span> <span class="o">=</span> <span class="nx">absN</span><span class="p">.</span><span class="nx">toFixed</span><span class="p">(</span><span class="nx">places</span><span class="p">)</span><span class="o">+</span><span class="s1">&#39;&#39;</span><span class="p">;</span>
            <span class="p">}</span>
        <span class="p">}</span>

        <span class="nx">bits</span>  <span class="o">=</span> <span class="nx">s</span><span class="p">.</span><span class="nx">split</span><span class="p">(</span><span class="sr">/\D/</span><span class="p">);</span>

        <span class="k">if</span> <span class="p">(</span><span class="nx">absN</span> <span class="o">&gt;=</span> <span class="mi">1000</span><span class="p">)</span> <span class="p">{</span>
            <span class="nx">i</span>  <span class="o">=</span> <span class="nx">bits</span><span class="p">[</span><span class="mi">0</span><span class="p">].</span><span class="nx">length</span> <span class="o">%</span> <span class="mi">3</span> <span class="o">||</span> <span class="mi">3</span><span class="p">;</span>

            <span class="nx">bits</span><span class="p">[</span><span class="mi">0</span><span class="p">]</span> <span class="o">=</span> <span class="nx">bits</span><span class="p">[</span><span class="mi">0</span><span class="p">].</span><span class="nx">slice</span><span class="p">(</span><span class="mi">0</span><span class="p">,</span><span class="nx">i</span><span class="p">)</span> <span class="o">+</span>
                      <span class="nx">bits</span><span class="p">[</span><span class="mi">0</span><span class="p">].</span><span class="nx">slice</span><span class="p">(</span><span class="nx">i</span><span class="p">).</span><span class="nx">replace</span><span class="p">(</span><span class="sr">/(\d{3})/g</span><span class="p">,</span> <span class="nx">sep</span> <span class="o">+</span> <span class="s1">&#39;$1&#39;</span><span class="p">);</span>

        <span class="p">}</span>

        <span class="k">return</span> <span class="nx">YAHOO</span><span class="p">.</span><span class="nx">util</span><span class="p">.</span><span class="nb">Number</span><span class="p">.</span><span class="nx">format</span><span class="p">.</span><span class="nx">_applyFormat</span><span class="p">(</span>
            <span class="p">(</span><span class="nx">n</span> <span class="o">&lt;</span> <span class="mi">0</span> <span class="o">?</span> <span class="nx">negFmt</span> <span class="o">:</span> <span class="nx">cfg</span><span class="p">.</span><span class="nx">format</span><span class="p">),</span>
            <span class="nx">bits</span><span class="p">.</span><span class="nx">join</span><span class="p">(</span><span class="nx">cfg</span><span class="p">.</span><span class="nx">decimalSeparator</span><span class="p">),</span>
            <span class="nx">cfg</span><span class="p">);</span>
    <span class="p">}</span>
<span class="p">};</span>

<span class="cm">/**</span>
<span class="cm"> * &lt;p&gt;Default values for Number.format behavior.  Override properties of this</span>
<span class="cm"> * object if you want every call to Number.format in your system to use</span>
<span class="cm"> * specific presets.&lt;/p&gt;</span>
<span class="cm"> *</span>
<span class="cm"> * &lt;p&gt;Available keys include:&lt;/p&gt;</span>
<span class="cm"> * &lt;ul&gt;</span>
<span class="cm"> *   &lt;li&gt;format&lt;/li&gt;</span>
<span class="cm"> *   &lt;li&gt;negativeFormat&lt;/li&gt;</span>
<span class="cm"> *   &lt;li&gt;decimalSeparator&lt;/li&gt;</span>
<span class="cm"> *   &lt;li&gt;decimalPlaces&lt;/li&gt;</span>
<span class="cm"> *   &lt;li&gt;thousandsSeparator&lt;/li&gt;</span>
<span class="cm"> *   &lt;li&gt;prefix/suffix or any other token you want to use in the format templates&lt;/li&gt;</span>
<span class="cm"> * &lt;/ul&gt;</span>
<span class="cm"> *</span>
<span class="cm"> * @property Number.format.defaults</span>
<span class="cm"> * @type {Object}</span>
<span class="cm"> * @static</span>
<span class="cm"> */</span>
<span class="nx">YAHOO</span><span class="p">.</span><span class="nx">util</span><span class="p">.</span><span class="nb">Number</span><span class="p">.</span><span class="nx">format</span><span class="p">.</span><span class="nx">defaults</span> <span class="o">=</span> <span class="p">{</span>
    <span class="nx">format</span> <span class="o">:</span> <span class="s1">&#39;{prefix}{number}{suffix}&#39;</span><span class="p">,</span>
    <span class="nx">negativeFormat</span> <span class="o">:</span> <span class="kc">null</span><span class="p">,</span> <span class="c1">// defaults to -(format)</span>
    <span class="nx">decimalSeparator</span> <span class="o">:</span> <span class="s1">&#39;.&#39;</span><span class="p">,</span>
    <span class="nx">decimalPlaces</span>    <span class="o">:</span> <span class="kc">null</span><span class="p">,</span>
    <span class="nx">thousandsSeparator</span> <span class="o">:</span> <span class="s1">&#39;&#39;</span>
<span class="p">};</span>

<span class="cm">/**</span>
<span class="cm"> * Apply any special formatting to the &quot;d,ddd.dd&quot; string.  Takes either the</span>
<span class="cm"> * cfg.format or cfg.negativeFormat template and replaces any {placeholders}</span>
<span class="cm"> * with either the number or a value from a so-named property of the config</span>
<span class="cm"> * object.</span>
<span class="cm"> *</span>
<span class="cm"> * @method Number.format._applyFormat</span>
<span class="cm"> * @static</span>
<span class="cm"> * @param tmpl {String} the cfg.format or cfg.numberFormat template string</span>
<span class="cm"> * @param num {String} the number with separators and decimalPlaces applied</span>
<span class="cm"> * @param data {Object} the config object, used here to populate {placeholder}s</span>
<span class="cm"> * @return {String} the number with any decorators added</span>
<span class="cm"> */</span>
<span class="nx">YAHOO</span><span class="p">.</span><span class="nx">util</span><span class="p">.</span><span class="nb">Number</span><span class="p">.</span><span class="nx">format</span><span class="p">.</span><span class="nx">_applyFormat</span> <span class="o">=</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">tmpl</span><span class="p">,</span> <span class="nx">num</span><span class="p">,</span> <span class="nx">data</span><span class="p">)</span> <span class="p">{</span>
    <span class="k">return</span> <span class="nx">tmpl</span><span class="p">.</span><span class="nx">replace</span><span class="p">(</span><span class="sr">/\{(\w+)\}/g</span><span class="p">,</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">_</span><span class="p">,</span> <span class="nx">token</span><span class="p">)</span> <span class="p">{</span>
        <span class="k">return</span> <span class="nx">token</span> <span class="o">===</span> <span class="s1">&#39;number&#39;</span> <span class="o">?</span> <span class="nx">num</span> <span class="o">:</span>
               <span class="nx">token</span> <span class="k">in</span> <span class="nx">data</span> <span class="o">?</span> <span class="nx">data</span><span class="p">[</span><span class="nx">token</span><span class="p">]</span> <span class="o">:</span> <span class="s1">&#39;&#39;</span><span class="p">;</span>
    <span class="p">});</span>
<span class="p">};</span>


<span class="cm">/****************************************************************************/</span>
<span class="cm">/****************************************************************************/</span>
<span class="cm">/****************************************************************************/</span>

<span class="p">(</span><span class="kd">function</span> <span class="p">()</span> <span class="p">{</span>

<span class="kd">var</span> <span class="nx">xPad</span><span class="o">=</span><span class="kd">function</span> <span class="p">(</span><span class="nx">x</span><span class="p">,</span> <span class="nx">pad</span><span class="p">,</span> <span class="nx">r</span><span class="p">)</span>
<span class="p">{</span>
    <span class="k">if</span><span class="p">(</span><span class="k">typeof</span> <span class="nx">r</span> <span class="o">===</span> <span class="s1">&#39;undefined&#39;</span><span class="p">)</span>
    <span class="p">{</span>
        <span class="nx">r</span><span class="o">=</span><span class="mi">10</span><span class="p">;</span>
    <span class="p">}</span>
    <span class="k">for</span><span class="p">(</span> <span class="p">;</span> <span class="nb">parseInt</span><span class="p">(</span><span class="nx">x</span><span class="p">,</span> <span class="mi">10</span><span class="p">)</span><span class="o">&lt;</span><span class="nx">r</span> <span class="o">&amp;&amp;</span> <span class="nx">r</span><span class="o">&gt;</span><span class="mi">1</span><span class="p">;</span> <span class="nx">r</span><span class="o">/=</span><span class="mi">10</span><span class="p">)</span> <span class="p">{</span>
        <span class="nx">x</span> <span class="o">=</span> <span class="nx">pad</span><span class="p">.</span><span class="nx">toString</span><span class="p">()</span> <span class="o">+</span> <span class="nx">x</span><span class="p">;</span>
    <span class="p">}</span>
    <span class="k">return</span> <span class="nx">x</span><span class="p">.</span><span class="nx">toString</span><span class="p">();</span>
<span class="p">};</span>


<span class="cm">/**</span>
<span class="cm"> * The static Date class provides helper functions to deal with data of type Date.</span>
<span class="cm"> *</span>
<span class="cm"> * @namespace YAHOO.util</span>
<span class="cm"> * @requires yahoo</span>
<span class="cm"> * @class Date</span>
<span class="cm"> * @static</span>
<span class="cm"> */</span>
 <span class="kd">var</span> <span class="nx">Dt</span> <span class="o">=</span> <span class="p">{</span>
    <span class="nx">formats</span><span class="o">:</span> <span class="p">{</span>
        <span class="nx">a</span><span class="o">:</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">d</span><span class="p">,</span> <span class="nx">l</span><span class="p">)</span> <span class="p">{</span> <span class="k">return</span> <span class="nx">l</span><span class="p">.</span><span class="nx">a</span><span class="p">[</span><span class="nx">d</span><span class="p">.</span><span class="nx">getDay</span><span class="p">()];</span> <span class="p">},</span>
        <span class="nx">A</span><span class="o">:</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">d</span><span class="p">,</span> <span class="nx">l</span><span class="p">)</span> <span class="p">{</span> <span class="k">return</span> <span class="nx">l</span><span class="p">.</span><span class="nx">A</span><span class="p">[</span><span class="nx">d</span><span class="p">.</span><span class="nx">getDay</span><span class="p">()];</span> <span class="p">},</span>
        <span class="nx">b</span><span class="o">:</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">d</span><span class="p">,</span> <span class="nx">l</span><span class="p">)</span> <span class="p">{</span> <span class="k">return</span> <span class="nx">l</span><span class="p">.</span><span class="nx">b</span><span class="p">[</span><span class="nx">d</span><span class="p">.</span><span class="nx">getMonth</span><span class="p">()];</span> <span class="p">},</span>
        <span class="nx">B</span><span class="o">:</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">d</span><span class="p">,</span> <span class="nx">l</span><span class="p">)</span> <span class="p">{</span> <span class="k">return</span> <span class="nx">l</span><span class="p">.</span><span class="nx">B</span><span class="p">[</span><span class="nx">d</span><span class="p">.</span><span class="nx">getMonth</span><span class="p">()];</span> <span class="p">},</span>
        <span class="nx">C</span><span class="o">:</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">d</span><span class="p">)</span> <span class="p">{</span> <span class="k">return</span> <span class="nx">xPad</span><span class="p">(</span><span class="nb">parseInt</span><span class="p">(</span><span class="nx">d</span><span class="p">.</span><span class="nx">getFullYear</span><span class="p">()</span><span class="o">/</span><span class="mi">100</span><span class="p">,</span> <span class="mi">10</span><span class="p">),</span> <span class="mi">0</span><span class="p">);</span> <span class="p">},</span>
        <span class="nx">d</span><span class="o">:</span> <span class="p">[</span><span class="s1">&#39;getDate&#39;</span><span class="p">,</span> <span class="s1">&#39;0&#39;</span><span class="p">],</span>
        <span class="nx">e</span><span class="o">:</span> <span class="p">[</span><span class="s1">&#39;getDate&#39;</span><span class="p">,</span> <span class="s1">&#39; &#39;</span><span class="p">],</span>
        <span class="nx">g</span><span class="o">:</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">d</span><span class="p">)</span> <span class="p">{</span> <span class="k">return</span> <span class="nx">xPad</span><span class="p">(</span><span class="nb">parseInt</span><span class="p">(</span><span class="nx">Dt</span><span class="p">.</span><span class="nx">formats</span><span class="p">.</span><span class="nx">G</span><span class="p">(</span><span class="nx">d</span><span class="p">)</span><span class="o">%</span><span class="mi">100</span><span class="p">,</span> <span class="mi">10</span><span class="p">),</span> <span class="mi">0</span><span class="p">);</span> <span class="p">},</span>
        <span class="nx">G</span><span class="o">:</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">d</span><span class="p">)</span> <span class="p">{</span>
                <span class="kd">var</span> <span class="nx">y</span> <span class="o">=</span> <span class="nx">d</span><span class="p">.</span><span class="nx">getFullYear</span><span class="p">();</span>
                <span class="kd">var</span> <span class="nx">V</span> <span class="o">=</span> <span class="nb">parseInt</span><span class="p">(</span><span class="nx">Dt</span><span class="p">.</span><span class="nx">formats</span><span class="p">.</span><span class="nx">V</span><span class="p">(</span><span class="nx">d</span><span class="p">),</span> <span class="mi">10</span><span class="p">);</span>
                <span class="kd">var</span> <span class="nx">W</span> <span class="o">=</span> <span class="nb">parseInt</span><span class="p">(</span><span class="nx">Dt</span><span class="p">.</span><span class="nx">formats</span><span class="p">.</span><span class="nx">W</span><span class="p">(</span><span class="nx">d</span><span class="p">),</span> <span class="mi">10</span><span class="p">);</span>
    
                <span class="k">if</span><span class="p">(</span><span class="nx">W</span> <span class="o">&gt;</span> <span class="nx">V</span><span class="p">)</span> <span class="p">{</span>
                    <span class="nx">y</span><span class="o">++</span><span class="p">;</span>
                <span class="p">}</span> <span class="k">else</span> <span class="k">if</span><span class="p">(</span><span class="nx">W</span><span class="o">===</span><span class="mi">0</span> <span class="o">&amp;&amp;</span> <span class="nx">V</span><span class="o">&gt;=</span><span class="mi">52</span><span class="p">)</span> <span class="p">{</span>
                    <span class="nx">y</span><span class="o">--</span><span class="p">;</span>
                <span class="p">}</span>
    
                <span class="k">return</span> <span class="nx">y</span><span class="p">;</span>
            <span class="p">},</span>
        <span class="nx">H</span><span class="o">:</span> <span class="p">[</span><span class="s1">&#39;getHours&#39;</span><span class="p">,</span> <span class="s1">&#39;0&#39;</span><span class="p">],</span>
        <span class="nx">I</span><span class="o">:</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">d</span><span class="p">)</span> <span class="p">{</span> <span class="kd">var</span> <span class="nx">I</span><span class="o">=</span><span class="nx">d</span><span class="p">.</span><span class="nx">getHours</span><span class="p">()</span><span class="o">%</span><span class="mi">12</span><span class="p">;</span> <span class="k">return</span> <span class="nx">xPad</span><span class="p">(</span><span class="nx">I</span><span class="o">===</span><span class="mi">0</span><span class="o">?</span><span class="mi">12</span><span class="o">:</span><span class="nx">I</span><span class="p">,</span> <span class="mi">0</span><span class="p">);</span> <span class="p">},</span>
        <span class="nx">j</span><span class="o">:</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">d</span><span class="p">)</span> <span class="p">{</span>
                <span class="kd">var</span> <span class="nx">gmd_1</span> <span class="o">=</span> <span class="k">new</span> <span class="nb">Date</span><span class="p">(</span><span class="s1">&#39;&#39;</span> <span class="o">+</span> <span class="nx">d</span><span class="p">.</span><span class="nx">getFullYear</span><span class="p">()</span> <span class="o">+</span> <span class="s1">&#39;/1/1 GMT&#39;</span><span class="p">);</span>
                <span class="kd">var</span> <span class="nx">gmdate</span> <span class="o">=</span> <span class="k">new</span> <span class="nb">Date</span><span class="p">(</span><span class="s1">&#39;&#39;</span> <span class="o">+</span> <span class="nx">d</span><span class="p">.</span><span class="nx">getFullYear</span><span class="p">()</span> <span class="o">+</span> <span class="s1">&#39;/&#39;</span> <span class="o">+</span> <span class="p">(</span><span class="nx">d</span><span class="p">.</span><span class="nx">getMonth</span><span class="p">()</span><span class="o">+</span><span class="mi">1</span><span class="p">)</span> <span class="o">+</span> <span class="s1">&#39;/&#39;</span> <span class="o">+</span> <span class="nx">d</span><span class="p">.</span><span class="nx">getDate</span><span class="p">()</span> <span class="o">+</span> <span class="s1">&#39; GMT&#39;</span><span class="p">);</span>
                <span class="kd">var</span> <span class="nx">ms</span> <span class="o">=</span> <span class="nx">gmdate</span> <span class="o">-</span> <span class="nx">gmd_1</span><span class="p">;</span>
                <span class="kd">var</span> <span class="nx">doy</span> <span class="o">=</span> <span class="nb">parseInt</span><span class="p">(</span><span class="nx">ms</span><span class="o">/</span><span class="mi">60000</span><span class="o">/</span><span class="mi">60</span><span class="o">/</span><span class="mi">24</span><span class="p">,</span> <span class="mi">10</span><span class="p">)</span><span class="o">+</span><span class="mi">1</span><span class="p">;</span>
                <span class="k">return</span> <span class="nx">xPad</span><span class="p">(</span><span class="nx">doy</span><span class="p">,</span> <span class="mi">0</span><span class="p">,</span> <span class="mi">100</span><span class="p">);</span>
            <span class="p">},</span>
        <span class="nx">k</span><span class="o">:</span> <span class="p">[</span><span class="s1">&#39;getHours&#39;</span><span class="p">,</span> <span class="s1">&#39; &#39;</span><span class="p">],</span>
        <span class="nx">l</span><span class="o">:</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">d</span><span class="p">)</span> <span class="p">{</span> <span class="kd">var</span> <span class="nx">I</span><span class="o">=</span><span class="nx">d</span><span class="p">.</span><span class="nx">getHours</span><span class="p">()</span><span class="o">%</span><span class="mi">12</span><span class="p">;</span> <span class="k">return</span> <span class="nx">xPad</span><span class="p">(</span><span class="nx">I</span><span class="o">===</span><span class="mi">0</span><span class="o">?</span><span class="mi">12</span><span class="o">:</span><span class="nx">I</span><span class="p">,</span> <span class="s1">&#39; &#39;</span><span class="p">);</span> <span class="p">},</span>
        <span class="nx">m</span><span class="o">:</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">d</span><span class="p">)</span> <span class="p">{</span> <span class="k">return</span> <span class="nx">xPad</span><span class="p">(</span><span class="nx">d</span><span class="p">.</span><span class="nx">getMonth</span><span class="p">()</span><span class="o">+</span><span class="mi">1</span><span class="p">,</span> <span class="mi">0</span><span class="p">);</span> <span class="p">},</span>
        <span class="nx">M</span><span class="o">:</span> <span class="p">[</span><span class="s1">&#39;getMinutes&#39;</span><span class="p">,</span> <span class="s1">&#39;0&#39;</span><span class="p">],</span>
        <span class="nx">p</span><span class="o">:</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">d</span><span class="p">,</span> <span class="nx">l</span><span class="p">)</span> <span class="p">{</span> <span class="k">return</span> <span class="nx">l</span><span class="p">.</span><span class="nx">p</span><span class="p">[</span><span class="nx">d</span><span class="p">.</span><span class="nx">getHours</span><span class="p">()</span> <span class="o">&gt;=</span> <span class="mi">12</span> <span class="o">?</span> <span class="mi">1</span> <span class="o">:</span> <span class="mi">0</span> <span class="p">];</span> <span class="p">},</span>
        <span class="nx">P</span><span class="o">:</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">d</span><span class="p">,</span> <span class="nx">l</span><span class="p">)</span> <span class="p">{</span> <span class="k">return</span> <span class="nx">l</span><span class="p">.</span><span class="nx">P</span><span class="p">[</span><span class="nx">d</span><span class="p">.</span><span class="nx">getHours</span><span class="p">()</span> <span class="o">&gt;=</span> <span class="mi">12</span> <span class="o">?</span> <span class="mi">1</span> <span class="o">:</span> <span class="mi">0</span> <span class="p">];</span> <span class="p">},</span>
        <span class="nx">s</span><span class="o">:</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">d</span><span class="p">,</span> <span class="nx">l</span><span class="p">)</span> <span class="p">{</span> <span class="k">return</span> <span class="nb">parseInt</span><span class="p">(</span><span class="nx">d</span><span class="p">.</span><span class="nx">getTime</span><span class="p">()</span><span class="o">/</span><span class="mi">1000</span><span class="p">,</span> <span class="mi">10</span><span class="p">);</span> <span class="p">},</span>
        <span class="nx">S</span><span class="o">:</span> <span class="p">[</span><span class="s1">&#39;getSeconds&#39;</span><span class="p">,</span> <span class="s1">&#39;0&#39;</span><span class="p">],</span>
        <span class="nx">u</span><span class="o">:</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">d</span><span class="p">)</span> <span class="p">{</span> <span class="kd">var</span> <span class="nx">dow</span> <span class="o">=</span> <span class="nx">d</span><span class="p">.</span><span class="nx">getDay</span><span class="p">();</span> <span class="k">return</span> <span class="nx">dow</span><span class="o">===</span><span class="mi">0</span><span class="o">?</span><span class="mi">7</span><span class="o">:</span><span class="nx">dow</span><span class="p">;</span> <span class="p">},</span>
        <span class="nx">U</span><span class="o">:</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">d</span><span class="p">)</span> <span class="p">{</span>
                <span class="kd">var</span> <span class="nx">doy</span> <span class="o">=</span> <span class="nb">parseInt</span><span class="p">(</span><span class="nx">Dt</span><span class="p">.</span><span class="nx">formats</span><span class="p">.</span><span class="nx">j</span><span class="p">(</span><span class="nx">d</span><span class="p">),</span> <span class="mi">10</span><span class="p">);</span>
                <span class="kd">var</span> <span class="nx">rdow</span> <span class="o">=</span> <span class="mi">6</span><span class="o">-</span><span class="nx">d</span><span class="p">.</span><span class="nx">getDay</span><span class="p">();</span>
                <span class="kd">var</span> <span class="nx">woy</span> <span class="o">=</span> <span class="nb">parseInt</span><span class="p">((</span><span class="nx">doy</span><span class="o">+</span><span class="nx">rdow</span><span class="p">)</span><span class="o">/</span><span class="mi">7</span><span class="p">,</span> <span class="mi">10</span><span class="p">);</span>
                <span class="k">return</span> <span class="nx">xPad</span><span class="p">(</span><span class="nx">woy</span><span class="p">,</span> <span class="mi">0</span><span class="p">);</span>
            <span class="p">},</span>
        <span class="nx">V</span><span class="o">:</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">d</span><span class="p">)</span> <span class="p">{</span>
                <span class="kd">var</span> <span class="nx">woy</span> <span class="o">=</span> <span class="nb">parseInt</span><span class="p">(</span><span class="nx">Dt</span><span class="p">.</span><span class="nx">formats</span><span class="p">.</span><span class="nx">W</span><span class="p">(</span><span class="nx">d</span><span class="p">),</span> <span class="mi">10</span><span class="p">);</span>
                <span class="kd">var</span> <span class="nx">dow1_1</span> <span class="o">=</span> <span class="p">(</span><span class="k">new</span> <span class="nb">Date</span><span class="p">(</span><span class="s1">&#39;&#39;</span> <span class="o">+</span> <span class="nx">d</span><span class="p">.</span><span class="nx">getFullYear</span><span class="p">()</span> <span class="o">+</span> <span class="s1">&#39;/1/1&#39;</span><span class="p">)).</span><span class="nx">getDay</span><span class="p">();</span>
                <span class="c1">// First week is 01 and not 00 as in the case of %U and %W,</span>
                <span class="c1">// so we add 1 to the final result except if day 1 of the year</span>
                <span class="c1">// is a Monday (then %W returns 01).</span>
                <span class="c1">// We also need to subtract 1 if the day 1 of the year is </span>
                <span class="c1">// Friday-Sunday, so the resulting equation becomes:</span>
                <span class="kd">var</span> <span class="nx">idow</span> <span class="o">=</span> <span class="nx">woy</span> <span class="o">+</span> <span class="p">(</span><span class="nx">dow1_1</span> <span class="o">&gt;</span> <span class="mi">4</span> <span class="o">||</span> <span class="nx">dow1_1</span> <span class="o">&lt;=</span> <span class="mi">1</span> <span class="o">?</span> <span class="mi">0</span> <span class="o">:</span> <span class="mi">1</span><span class="p">);</span>
                <span class="k">if</span><span class="p">(</span><span class="nx">idow</span> <span class="o">===</span> <span class="mi">53</span> <span class="o">&amp;&amp;</span> <span class="p">(</span><span class="k">new</span> <span class="nb">Date</span><span class="p">(</span><span class="s1">&#39;&#39;</span> <span class="o">+</span> <span class="nx">d</span><span class="p">.</span><span class="nx">getFullYear</span><span class="p">()</span> <span class="o">+</span> <span class="s1">&#39;/12/31&#39;</span><span class="p">)).</span><span class="nx">getDay</span><span class="p">()</span> <span class="o">&lt;</span> <span class="mi">4</span><span class="p">)</span>
                <span class="p">{</span>
                    <span class="nx">idow</span> <span class="o">=</span> <span class="mi">1</span><span class="p">;</span>
                <span class="p">}</span>
                <span class="k">else</span> <span class="k">if</span><span class="p">(</span><span class="nx">idow</span> <span class="o">===</span> <span class="mi">0</span><span class="p">)</span>
                <span class="p">{</span>
                    <span class="nx">idow</span> <span class="o">=</span> <span class="nx">Dt</span><span class="p">.</span><span class="nx">formats</span><span class="p">.</span><span class="nx">V</span><span class="p">(</span><span class="k">new</span> <span class="nb">Date</span><span class="p">(</span><span class="s1">&#39;&#39;</span> <span class="o">+</span> <span class="p">(</span><span class="nx">d</span><span class="p">.</span><span class="nx">getFullYear</span><span class="p">()</span><span class="o">-</span><span class="mi">1</span><span class="p">)</span> <span class="o">+</span> <span class="s1">&#39;/12/31&#39;</span><span class="p">));</span>
                <span class="p">}</span>
    
                <span class="k">return</span> <span class="nx">xPad</span><span class="p">(</span><span class="nx">idow</span><span class="p">,</span> <span class="mi">0</span><span class="p">);</span>
            <span class="p">},</span>
        <span class="nx">w</span><span class="o">:</span> <span class="s1">&#39;getDay&#39;</span><span class="p">,</span>
        <span class="nx">W</span><span class="o">:</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">d</span><span class="p">)</span> <span class="p">{</span>
                <span class="kd">var</span> <span class="nx">doy</span> <span class="o">=</span> <span class="nb">parseInt</span><span class="p">(</span><span class="nx">Dt</span><span class="p">.</span><span class="nx">formats</span><span class="p">.</span><span class="nx">j</span><span class="p">(</span><span class="nx">d</span><span class="p">),</span> <span class="mi">10</span><span class="p">);</span>
                <span class="kd">var</span> <span class="nx">rdow</span> <span class="o">=</span> <span class="mi">7</span><span class="o">-</span><span class="nx">Dt</span><span class="p">.</span><span class="nx">formats</span><span class="p">.</span><span class="nx">u</span><span class="p">(</span><span class="nx">d</span><span class="p">);</span>
                <span class="kd">var</span> <span class="nx">woy</span> <span class="o">=</span> <span class="nb">parseInt</span><span class="p">((</span><span class="nx">doy</span><span class="o">+</span><span class="nx">rdow</span><span class="p">)</span><span class="o">/</span><span class="mi">7</span><span class="p">,</span> <span class="mi">10</span><span class="p">);</span>
                <span class="k">return</span> <span class="nx">xPad</span><span class="p">(</span><span class="nx">woy</span><span class="p">,</span> <span class="mi">0</span><span class="p">,</span> <span class="mi">10</span><span class="p">);</span>
            <span class="p">},</span>
        <span class="nx">y</span><span class="o">:</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">d</span><span class="p">)</span> <span class="p">{</span> <span class="k">return</span> <span class="nx">xPad</span><span class="p">(</span><span class="nx">d</span><span class="p">.</span><span class="nx">getFullYear</span><span class="p">()</span><span class="o">%</span><span class="mi">100</span><span class="p">,</span> <span class="mi">0</span><span class="p">);</span> <span class="p">},</span>
        <span class="nx">Y</span><span class="o">:</span> <span class="s1">&#39;getFullYear&#39;</span><span class="p">,</span>
        <span class="nx">z</span><span class="o">:</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">d</span><span class="p">)</span> <span class="p">{</span>
                <span class="kd">var</span> <span class="nx">o</span> <span class="o">=</span> <span class="nx">d</span><span class="p">.</span><span class="nx">getTimezoneOffset</span><span class="p">();</span>
                <span class="kd">var</span> <span class="nx">H</span> <span class="o">=</span> <span class="nx">xPad</span><span class="p">(</span><span class="nb">parseInt</span><span class="p">(</span><span class="nb">Math</span><span class="p">.</span><span class="nx">abs</span><span class="p">(</span><span class="nx">o</span><span class="o">/</span><span class="mi">60</span><span class="p">),</span> <span class="mi">10</span><span class="p">),</span> <span class="mi">0</span><span class="p">);</span>
                <span class="kd">var</span> <span class="nx">M</span> <span class="o">=</span> <span class="nx">xPad</span><span class="p">(</span><span class="nb">Math</span><span class="p">.</span><span class="nx">abs</span><span class="p">(</span><span class="nx">o</span><span class="o">%</span><span class="mi">60</span><span class="p">),</span> <span class="mi">0</span><span class="p">);</span>
                <span class="k">return</span> <span class="p">(</span><span class="nx">o</span><span class="o">&gt;</span><span class="mi">0</span><span class="o">?</span><span class="s1">&#39;-&#39;</span><span class="o">:</span><span class="s1">&#39;+&#39;</span><span class="p">)</span> <span class="o">+</span> <span class="nx">H</span> <span class="o">+</span> <span class="nx">M</span><span class="p">;</span>
            <span class="p">},</span>
        <span class="nx">Z</span><span class="o">:</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">d</span><span class="p">)</span> <span class="p">{</span>
		<span class="kd">var</span> <span class="nx">tz</span> <span class="o">=</span> <span class="nx">d</span><span class="p">.</span><span class="nx">toString</span><span class="p">().</span><span class="nx">replace</span><span class="p">(</span><span class="sr">/^.*:\d\d( GMT[+-]\d+)? \(?([A-Za-z ]+)\)?\d*$/</span><span class="p">,</span> <span class="s1">&#39;$2&#39;</span><span class="p">).</span><span class="nx">replace</span><span class="p">(</span><span class="sr">/[a-z ]/g</span><span class="p">,</span> <span class="s1">&#39;&#39;</span><span class="p">);</span>
		<span class="k">if</span><span class="p">(</span><span class="nx">tz</span><span class="p">.</span><span class="nx">length</span> <span class="o">&gt;</span> <span class="mi">4</span><span class="p">)</span> <span class="p">{</span>
			<span class="nx">tz</span> <span class="o">=</span> <span class="nx">Dt</span><span class="p">.</span><span class="nx">formats</span><span class="p">.</span><span class="nx">z</span><span class="p">(</span><span class="nx">d</span><span class="p">);</span>
		<span class="p">}</span>
		<span class="k">return</span> <span class="nx">tz</span><span class="p">;</span>
	<span class="p">},</span>
        <span class="s1">&#39;%&#39;</span><span class="o">:</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">d</span><span class="p">)</span> <span class="p">{</span> <span class="k">return</span> <span class="s1">&#39;%&#39;</span><span class="p">;</span> <span class="p">}</span>
    <span class="p">},</span>

    <span class="nx">aggregates</span><span class="o">:</span> <span class="p">{</span>
        <span class="nx">c</span><span class="o">:</span> <span class="s1">&#39;locale&#39;</span><span class="p">,</span>
        <span class="nx">D</span><span class="o">:</span> <span class="s1">&#39;%m/%d/%y&#39;</span><span class="p">,</span>
        <span class="nx">F</span><span class="o">:</span> <span class="s1">&#39;%Y-%m-%d&#39;</span><span class="p">,</span>
        <span class="nx">h</span><span class="o">:</span> <span class="s1">&#39;%b&#39;</span><span class="p">,</span>
        <span class="nx">n</span><span class="o">:</span> <span class="s1">&#39;\n&#39;</span><span class="p">,</span>
        <span class="nx">r</span><span class="o">:</span> <span class="s1">&#39;locale&#39;</span><span class="p">,</span>
        <span class="nx">R</span><span class="o">:</span> <span class="s1">&#39;%H:%M&#39;</span><span class="p">,</span>
        <span class="nx">t</span><span class="o">:</span> <span class="s1">&#39;\t&#39;</span><span class="p">,</span>
        <span class="nx">T</span><span class="o">:</span> <span class="s1">&#39;%H:%M:%S&#39;</span><span class="p">,</span>
        <span class="nx">x</span><span class="o">:</span> <span class="s1">&#39;locale&#39;</span><span class="p">,</span>
        <span class="nx">X</span><span class="o">:</span> <span class="s1">&#39;locale&#39;</span>
        <span class="c1">//&#39;+&#39;: &#39;%a %b %e %T %Z %Y&#39;</span>
    <span class="p">},</span>

     <span class="cm">/**</span>
<span class="cm">     * Takes a native JavaScript Date and formats to string for display to user.</span>
<span class="cm">     *</span>
<span class="cm">     * @method format</span>
<span class="cm">     * @param oDate {Date} Date.</span>
<span class="cm">     * @param oConfig {Object} (Optional) Object literal of configuration values:</span>
<span class="cm">     *  &lt;dl&gt;</span>
<span class="cm">     *   &lt;dt&gt;format &amp;lt;String&amp;gt;&lt;/dt&gt;</span>
<span class="cm">     *   &lt;dd&gt;</span>
<span class="cm">     *   &lt;p&gt;</span>
<span class="cm">     *   Any strftime string is supported, such as &quot;%I:%M:%S %p&quot;. strftime has several format specifiers defined by the Open group at </span>
<span class="cm">     *   &lt;a href=&quot;http://www.opengroup.org/onlinepubs/007908799/xsh/strftime.html&quot;&gt;http://www.opengroup.org/onlinepubs/007908799/xsh/strftime.html&lt;/a&gt;</span>
<span class="cm">     *   &lt;/p&gt;</span>
<span class="cm">     *   &lt;p&gt;   </span>
<span class="cm">     *   PHP added a few of its own, defined at &lt;a href=&quot;http://www.php.net/strftime&quot;&gt;http://www.php.net/strftime&lt;/a&gt;</span>
<span class="cm">     *   &lt;/p&gt;</span>
<span class="cm">     *   &lt;p&gt;</span>
<span class="cm">     *   This javascript implementation supports all the PHP specifiers and a few more.  The full list is below:</span>
<span class="cm">     *   &lt;/p&gt;</span>
<span class="cm">     *   &lt;dl&gt;</span>
<span class="cm">     *    &lt;dt&gt;%a&lt;/dt&gt; &lt;dd&gt;abbreviated weekday name according to the current locale&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%A&lt;/dt&gt; &lt;dd&gt;full weekday name according to the current locale&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%b&lt;/dt&gt; &lt;dd&gt;abbreviated month name according to the current locale&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%B&lt;/dt&gt; &lt;dd&gt;full month name according to the current locale&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%c&lt;/dt&gt; &lt;dd&gt;preferred date and time representation for the current locale&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%C&lt;/dt&gt; &lt;dd&gt;century number (the year divided by 100 and truncated to an integer, range 00 to 99)&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%d&lt;/dt&gt; &lt;dd&gt;day of the month as a decimal number (range 01 to 31)&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%D&lt;/dt&gt; &lt;dd&gt;same as %m/%d/%y&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%e&lt;/dt&gt; &lt;dd&gt;day of the month as a decimal number, a single digit is preceded by a space (range &#39; 1&#39; to &#39;31&#39;)&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%F&lt;/dt&gt; &lt;dd&gt;same as %Y-%m-%d (ISO 8601 date format)&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%g&lt;/dt&gt; &lt;dd&gt;like %G, but without the century&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%G&lt;/dt&gt; &lt;dd&gt;The 4-digit year corresponding to the ISO week number&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%h&lt;/dt&gt; &lt;dd&gt;same as %b&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%H&lt;/dt&gt; &lt;dd&gt;hour as a decimal number using a 24-hour clock (range 00 to 23)&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%I&lt;/dt&gt; &lt;dd&gt;hour as a decimal number using a 12-hour clock (range 01 to 12)&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%j&lt;/dt&gt; &lt;dd&gt;day of the year as a decimal number (range 001 to 366)&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%k&lt;/dt&gt; &lt;dd&gt;hour as a decimal number using a 24-hour clock (range 0 to 23); single digits are preceded by a blank. (See also %H.)&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%l&lt;/dt&gt; &lt;dd&gt;hour as a decimal number using a 12-hour clock (range 1 to 12); single digits are preceded by a blank. (See also %I.) &lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%m&lt;/dt&gt; &lt;dd&gt;month as a decimal number (range 01 to 12)&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%M&lt;/dt&gt; &lt;dd&gt;minute as a decimal number&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%n&lt;/dt&gt; &lt;dd&gt;newline character&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%p&lt;/dt&gt; &lt;dd&gt;either `AM&#39; or `PM&#39; according to the given time value, or the corresponding strings for the current locale&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%P&lt;/dt&gt; &lt;dd&gt;like %p, but lower case&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%r&lt;/dt&gt; &lt;dd&gt;time in a.m. and p.m. notation equal to %I:%M:%S %p&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%R&lt;/dt&gt; &lt;dd&gt;time in 24 hour notation equal to %H:%M&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%s&lt;/dt&gt; &lt;dd&gt;number of seconds since the Epoch, ie, since 1970-01-01 00:00:00 UTC&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%S&lt;/dt&gt; &lt;dd&gt;second as a decimal number&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%t&lt;/dt&gt; &lt;dd&gt;tab character&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%T&lt;/dt&gt; &lt;dd&gt;current time, equal to %H:%M:%S&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%u&lt;/dt&gt; &lt;dd&gt;weekday as a decimal number [1,7], with 1 representing Monday&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%U&lt;/dt&gt; &lt;dd&gt;week number of the current year as a decimal number, starting with the</span>
<span class="cm">     *            first Sunday as the first day of the first week&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%V&lt;/dt&gt; &lt;dd&gt;The ISO 8601:1988 week number of the current year as a decimal number,</span>
<span class="cm">     *            range 01 to 53, where week 1 is the first week that has at least 4 days</span>
<span class="cm">     *            in the current year, and with Monday as the first day of the week.&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%w&lt;/dt&gt; &lt;dd&gt;day of the week as a decimal, Sunday being 0&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%W&lt;/dt&gt; &lt;dd&gt;week number of the current year as a decimal number, starting with the</span>
<span class="cm">     *            first Monday as the first day of the first week&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%x&lt;/dt&gt; &lt;dd&gt;preferred date representation for the current locale without the time&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%X&lt;/dt&gt; &lt;dd&gt;preferred time representation for the current locale without the date&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%y&lt;/dt&gt; &lt;dd&gt;year as a decimal number without a century (range 00 to 99)&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%Y&lt;/dt&gt; &lt;dd&gt;year as a decimal number including the century&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%z&lt;/dt&gt; &lt;dd&gt;numerical time zone representation&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%Z&lt;/dt&gt; &lt;dd&gt;time zone name or abbreviation&lt;/dd&gt;</span>
<span class="cm">     *    &lt;dt&gt;%%&lt;/dt&gt; &lt;dd&gt;a literal `%&#39; character&lt;/dd&gt;</span>
<span class="cm">     *   &lt;/dl&gt;</span>
<span class="cm">     *  &lt;/dd&gt;</span>
<span class="cm">     * &lt;/dl&gt;</span>
<span class="cm">     * @param sLocale {String} (Optional) The locale to use when displaying days of week,</span>
<span class="cm">     *  months of the year, and other locale specific strings.  The following locales are</span>
<span class="cm">     *  built in:</span>
<span class="cm">     *  &lt;dl&gt;</span>
<span class="cm">     *   &lt;dt&gt;en&lt;/dt&gt;</span>
<span class="cm">     *   &lt;dd&gt;English&lt;/dd&gt;</span>
<span class="cm">     *   &lt;dt&gt;en-US&lt;/dt&gt;</span>
<span class="cm">     *   &lt;dd&gt;US English&lt;/dd&gt;</span>
<span class="cm">     *   &lt;dt&gt;en-GB&lt;/dt&gt;</span>
<span class="cm">     *   &lt;dd&gt;British English&lt;/dd&gt;</span>
<span class="cm">     *   &lt;dt&gt;en-AU&lt;/dt&gt;</span>
<span class="cm">     *   &lt;dd&gt;Australian English (identical to British English)&lt;/dd&gt;</span>
<span class="cm">     *  &lt;/dl&gt;</span>
<span class="cm">     *  More locales may be added by subclassing of YAHOO.util.DateLocale.</span>
<span class="cm">     *  See YAHOO.util.DateLocale for more information.</span>
<span class="cm">     * @return {HTML} Formatted date for display. Non-date values are passed</span>
<span class="cm">     * through as-is.</span>
<span class="cm">     * @sa YAHOO.util.DateLocale</span>
<span class="cm">     */</span>
    <span class="nx">format</span> <span class="o">:</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">oDate</span><span class="p">,</span> <span class="nx">oConfig</span><span class="p">,</span> <span class="nx">sLocale</span><span class="p">)</span> <span class="p">{</span>
        <span class="nx">oConfig</span> <span class="o">=</span> <span class="nx">oConfig</span> <span class="o">||</span> <span class="p">{};</span>
        
        <span class="k">if</span><span class="p">(</span><span class="o">!</span><span class="p">(</span><span class="nx">oDate</span> <span class="k">instanceof</span> <span class="nb">Date</span><span class="p">))</span> <span class="p">{</span>
            <span class="k">return</span> <span class="nx">YAHOO</span><span class="p">.</span><span class="nx">lang</span><span class="p">.</span><span class="nx">isValue</span><span class="p">(</span><span class="nx">oDate</span><span class="p">)</span> <span class="o">?</span> <span class="nx">oDate</span> <span class="o">:</span> <span class="s2">&quot;&quot;</span><span class="p">;</span>
        <span class="p">}</span>

        <span class="kd">var</span> <span class="nx">format</span> <span class="o">=</span> <span class="nx">oConfig</span><span class="p">.</span><span class="nx">format</span> <span class="o">||</span> <span class="s2">&quot;%m/%d/%Y&quot;</span><span class="p">;</span>

        <span class="c1">// Be backwards compatible, support strings that are</span>
        <span class="c1">// exactly equal to YYYY/MM/DD, DD/MM/YYYY and MM/DD/YYYY</span>
        <span class="k">if</span><span class="p">(</span><span class="nx">format</span> <span class="o">===</span> <span class="s1">&#39;YYYY/MM/DD&#39;</span><span class="p">)</span> <span class="p">{</span>
            <span class="nx">format</span> <span class="o">=</span> <span class="s1">&#39;%Y/%m/%d&#39;</span><span class="p">;</span>
        <span class="p">}</span> <span class="k">else</span> <span class="k">if</span><span class="p">(</span><span class="nx">format</span> <span class="o">===</span> <span class="s1">&#39;DD/MM/YYYY&#39;</span><span class="p">)</span> <span class="p">{</span>
            <span class="nx">format</span> <span class="o">=</span> <span class="s1">&#39;%d/%m/%Y&#39;</span><span class="p">;</span>
        <span class="p">}</span> <span class="k">else</span> <span class="k">if</span><span class="p">(</span><span class="nx">format</span> <span class="o">===</span> <span class="s1">&#39;MM/DD/YYYY&#39;</span><span class="p">)</span> <span class="p">{</span>
            <span class="nx">format</span> <span class="o">=</span> <span class="s1">&#39;%m/%d/%Y&#39;</span><span class="p">;</span>
        <span class="p">}</span>
        <span class="c1">// end backwards compatibility block</span>
 
        <span class="nx">sLocale</span> <span class="o">=</span> <span class="nx">sLocale</span> <span class="o">||</span> <span class="s2">&quot;en&quot;</span><span class="p">;</span>

        <span class="c1">// Make sure we have a definition for the requested locale, or default to en.</span>
        <span class="k">if</span><span class="p">(</span><span class="o">!</span><span class="p">(</span><span class="nx">sLocale</span> <span class="k">in</span> <span class="nx">YAHOO</span><span class="p">.</span><span class="nx">util</span><span class="p">.</span><span class="nx">DateLocale</span><span class="p">))</span> <span class="p">{</span>
            <span class="k">if</span><span class="p">(</span><span class="nx">sLocale</span><span class="p">.</span><span class="nx">replace</span><span class="p">(</span><span class="sr">/-[a-zA-Z]+$/</span><span class="p">,</span> <span class="s1">&#39;&#39;</span><span class="p">)</span> <span class="k">in</span> <span class="nx">YAHOO</span><span class="p">.</span><span class="nx">util</span><span class="p">.</span><span class="nx">DateLocale</span><span class="p">)</span> <span class="p">{</span>
                <span class="nx">sLocale</span> <span class="o">=</span> <span class="nx">sLocale</span><span class="p">.</span><span class="nx">replace</span><span class="p">(</span><span class="sr">/-[a-zA-Z]+$/</span><span class="p">,</span> <span class="s1">&#39;&#39;</span><span class="p">);</span>
            <span class="p">}</span> <span class="k">else</span> <span class="p">{</span>
                <span class="nx">sLocale</span> <span class="o">=</span> <span class="s2">&quot;en&quot;</span><span class="p">;</span>
            <span class="p">}</span>
        <span class="p">}</span>

        <span class="kd">var</span> <span class="nx">aLocale</span> <span class="o">=</span> <span class="nx">YAHOO</span><span class="p">.</span><span class="nx">util</span><span class="p">.</span><span class="nx">DateLocale</span><span class="p">[</span><span class="nx">sLocale</span><span class="p">];</span>

        <span class="kd">var</span> <span class="nx">replace_aggs</span> <span class="o">=</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">m0</span><span class="p">,</span> <span class="nx">m1</span><span class="p">)</span> <span class="p">{</span>
            <span class="kd">var</span> <span class="nx">f</span> <span class="o">=</span> <span class="nx">Dt</span><span class="p">.</span><span class="nx">aggregates</span><span class="p">[</span><span class="nx">m1</span><span class="p">];</span>
            <span class="k">return</span> <span class="p">(</span><span class="nx">f</span> <span class="o">===</span> <span class="s1">&#39;locale&#39;</span> <span class="o">?</span> <span class="nx">aLocale</span><span class="p">[</span><span class="nx">m1</span><span class="p">]</span> <span class="o">:</span> <span class="nx">f</span><span class="p">);</span>
        <span class="p">};</span>

        <span class="kd">var</span> <span class="nx">replace_formats</span> <span class="o">=</span> <span class="kd">function</span> <span class="p">(</span><span class="nx">m0</span><span class="p">,</span> <span class="nx">m1</span><span class="p">)</span> <span class="p">{</span>
            <span class="kd">var</span> <span class="nx">f</span> <span class="o">=</span> <span class="nx">Dt</span><span class="p">.</span><span class="nx">formats</span><span class="p">[</span><span class="nx">m1</span><span class="p">];</span>
            <span class="k">if</span><span class="p">(</span><span class="k">typeof</span> <span class="nx">f</span> <span class="o">===</span> <span class="s1">&#39;string&#39;</span><span class="p">)</span> <span class="p">{</span>             <span class="c1">// string =&gt; built in date function</span>
                <span class="k">return</span> <span class="nx">oDate</span><span class="p">[</span><span class="nx">f</span><span class="p">]();</span>
            <span class="p">}</span> <span class="k">else</span> <span class="k">if</span><span class="p">(</span><span class="k">typeof</span> <span class="nx">f</span> <span class="o">===</span> <span class="s1">&#39;function&#39;</span><span class="p">)</span> <span class="p">{</span>    <span class="c1">// function =&gt; our own function</span>
                <span class="k">return</span> <span class="nx">f</span><span class="p">.</span><span class="nx">call</span><span class="p">(</span><span class="nx">oDate</span><span class="p">,</span> <span class="nx">oDate</span><span class="p">,</span> <span class="nx">aLocale</span><span class="p">);</span>
            <span class="p">}</span> <span class="k">else</span> <span class="k">if</span><span class="p">(</span><span class="k">typeof</span> <span class="nx">f</span> <span class="o">===</span> <span class="s1">&#39;object&#39;</span> <span class="o">&amp;&amp;</span> <span class="k">typeof</span> <span class="nx">f</span><span class="p">[</span><span class="mi">0</span><span class="p">]</span> <span class="o">===</span> <span class="s1">&#39;string&#39;</span><span class="p">)</span> <span class="p">{</span>  <span class="c1">// built in function with padding</span>
                <span class="k">return</span> <span class="nx">xPad</span><span class="p">(</span><span class="nx">oDate</span><span class="p">[</span><span class="nx">f</span><span class="p">[</span><span class="mi">0</span><span class="p">]](),</span> <span class="nx">f</span><span class="p">[</span><span class="mi">1</span><span class="p">]);</span>
            <span class="p">}</span> <span class="k">else</span> <span class="p">{</span>
                <span class="k">return</span> <span class="nx">m1</span><span class="p">;</span>
            <span class="p">}</span>
        <span class="p">};</span>

        <span class="c1">// First replace aggregates (run in a loop because an agg may be made up of other aggs)</span>
        <span class="k">while</span><span class="p">(</span><span class="nx">format</span><span class="p">.</span><span class="nx">match</span><span class="p">(</span><span class="sr">/%[cDFhnrRtTxX]/</span><span class="p">))</span> <span class="p">{</span>
            <span class="nx">format</span> <span class="o">=</span> <span class="nx">format</span><span class="p">.</span><span class="nx">replace</span><span class="p">(</span><span class="sr">/%([cDFhnrRtTxX])/g</span><span class="p">,</span> <span class="nx">replace_aggs</span><span class="p">);</span>
        <span class="p">}</span>

        <span class="c1">// Now replace formats (do not run in a loop otherwise %%a will be replace with the value of %a)</span>
        <span class="kd">var</span> <span class="nx">str</span> <span class="o">=</span> <span class="nx">format</span><span class="p">.</span><span class="nx">replace</span><span class="p">(</span><span class="sr">/%([aAbBCdegGHIjklmMpPsSuUVwWyYzZ%])/g</span><span class="p">,</span> <span class="nx">replace_formats</span><span class="p">);</span>

        <span class="nx">replace_aggs</span> <span class="o">=</span> <span class="nx">replace_formats</span> <span class="o">=</span> <span class="kc">undefined</span><span class="p">;</span>

        <span class="k">return</span> <span class="nx">str</span><span class="p">;</span>
    <span class="p">}</span>
 <span class="p">};</span>
 
 <span class="nx">YAHOO</span><span class="p">.</span><span class="nx">namespace</span><span class="p">(</span><span class="s2">&quot;YAHOO.util&quot;</span><span class="p">);</span>
 <span class="nx">YAHOO</span><span class="p">.</span><span class="nx">util</span><span class="p">.</span><span class="nb">Date</span> <span class="o">=</span> <span class="nx">Dt</span><span class="p">;</span>

<span class="cm">/**</span>
<span class="cm"> * The DateLocale class is a container and base class for all</span>
<span class="cm"> * localised date strings used by YAHOO.util.Date. It is used</span>
<span class="cm"> * internally, but may be extended to provide new date localisations.</span>
<span class="cm"> *</span>
<span class="cm"> * To create your own DateLocale, follow these steps:</span>
<span class="cm"> * &lt;ol&gt;</span>
<span class="cm"> *  &lt;li&gt;Find an existing locale that matches closely with your needs&lt;/li&gt;</span>
<span class="cm"> *  &lt;li&gt;Use this as your base class.  Use YAHOO.util.DateLocale if nothing</span>
<span class="cm"> *   matches.&lt;/li&gt;</span>
<span class="cm"> *  &lt;li&gt;Create your own class as an extension of the base class using</span>
<span class="cm"> *   YAHOO.lang.merge, and add your own localisations where needed.&lt;/li&gt;</span>
<span class="cm"> * &lt;/ol&gt;</span>
<span class="cm"> * See the YAHOO.util.DateLocale[&#39;en-US&#39;] and YAHOO.util.DateLocale[&#39;en-GB&#39;]</span>
<span class="cm"> * classes which extend YAHOO.util.DateLocale[&#39;en&#39;].</span>
<span class="cm"> *</span>
<span class="cm"> * For example, to implement locales for French french and Canadian french,</span>
<span class="cm"> * we would do the following:</span>
<span class="cm"> * &lt;ol&gt;</span>
<span class="cm"> *  &lt;li&gt;For French french, we have no existing similar locale, so use</span>
<span class="cm"> *   YAHOO.util.DateLocale as the base, and extend it:</span>
<span class="cm"> *   &lt;pre&gt;</span>
<span class="cm"> *      YAHOO.util.DateLocale[&#39;fr&#39;] = YAHOO.lang.merge(YAHOO.util.DateLocale, {</span>
<span class="cm"> *          a: [&#39;dim&#39;, &#39;lun&#39;, &#39;mar&#39;, &#39;mer&#39;, &#39;jeu&#39;, &#39;ven&#39;, &#39;sam&#39;],</span>
<span class="cm"> *          A: [&#39;dimanche&#39;, &#39;lundi&#39;, &#39;mardi&#39;, &#39;mercredi&#39;, &#39;jeudi&#39;, &#39;vendredi&#39;, &#39;samedi&#39;],</span>
<span class="cm"> *          b: [&#39;jan&#39;, &#39;f&amp;eacute;v&#39;, &#39;mar&#39;, &#39;avr&#39;, &#39;mai&#39;, &#39;jun&#39;, &#39;jui&#39;, &#39;ao&amp;ucirc;&#39;, &#39;sep&#39;, &#39;oct&#39;, &#39;nov&#39;, &#39;d&amp;eacute;c&#39;],</span>
<span class="cm"> *          B: [&#39;janvier&#39;, &#39;f&amp;eacute;vrier&#39;, &#39;mars&#39;, &#39;avril&#39;, &#39;mai&#39;, &#39;juin&#39;, &#39;juillet&#39;, &#39;ao&amp;ucirc;t&#39;, &#39;septembre&#39;, &#39;octobre&#39;, &#39;novembre&#39;, &#39;d&amp;eacute;cembre&#39;],</span>
<span class="cm"> *          c: &#39;%a %d %b %Y %T %Z&#39;,</span>
<span class="cm"> *          p: [&#39;&#39;, &#39;&#39;],</span>
<span class="cm"> *          P: [&#39;&#39;, &#39;&#39;],</span>
<span class="cm"> *          x: &#39;%d.%m.%Y&#39;,</span>
<span class="cm"> *          X: &#39;%T&#39;</span>
<span class="cm"> *      });</span>
<span class="cm"> *   &lt;/pre&gt;</span>
<span class="cm"> *  &lt;/li&gt;</span>
<span class="cm"> *  &lt;li&gt;For Canadian french, we start with French french and change the meaning of \%x:</span>
<span class="cm"> *   &lt;pre&gt;</span>
<span class="cm"> *      YAHOO.util.DateLocale[&#39;fr-CA&#39;] = YAHOO.lang.merge(YAHOO.util.DateLocale[&#39;fr&#39;], {</span>
<span class="cm"> *          x: &#39;%Y-%m-%d&#39;</span>
<span class="cm"> *      });</span>
<span class="cm"> *   &lt;/pre&gt;</span>
<span class="cm"> *  &lt;/li&gt;</span>
<span class="cm"> * &lt;/ol&gt;</span>
<span class="cm"> *</span>
<span class="cm"> * With that, you can use your new locales:</span>
<span class="cm"> * &lt;pre&gt;</span>
<span class="cm"> *    var d = new Date(&quot;2008/04/22&quot;);</span>
<span class="cm"> *    YAHOO.util.Date.format(d, {format: &quot;%A, %d %B == %x&quot;}, &quot;fr&quot;);</span>
<span class="cm"> * &lt;/pre&gt;</span>
<span class="cm"> * will return:</span>
<span class="cm"> * &lt;pre&gt;</span>
<span class="cm"> *    mardi, 22 avril == 22.04.2008</span>
<span class="cm"> * &lt;/pre&gt;</span>
<span class="cm"> * And</span>
<span class="cm"> * &lt;pre&gt;</span>
<span class="cm"> *    YAHOO.util.Date.format(d, {format: &quot;%A, %d %B == %x&quot;}, &quot;fr-CA&quot;);</span>
<span class="cm"> * &lt;/pre&gt;</span>
<span class="cm"> * Will return:</span>
<span class="cm"> * &lt;pre&gt;</span>
<span class="cm"> *   mardi, 22 avril == 2008-04-22</span>
<span class="cm"> * &lt;/pre&gt;</span>
<span class="cm"> * @namespace YAHOO.util</span>
<span class="cm"> * @requires yahoo</span>
<span class="cm"> * @class DateLocale</span>
<span class="cm"> */</span>
 <span class="nx">YAHOO</span><span class="p">.</span><span class="nx">util</span><span class="p">.</span><span class="nx">DateLocale</span> <span class="o">=</span> <span class="p">{</span>
        <span class="nx">a</span><span class="o">:</span> <span class="p">[</span><span class="s1">&#39;Sun&#39;</span><span class="p">,</span> <span class="s1">&#39;Mon&#39;</span><span class="p">,</span> <span class="s1">&#39;Tue&#39;</span><span class="p">,</span> <span class="s1">&#39;Wed&#39;</span><span class="p">,</span> <span class="s1">&#39;Thu&#39;</span><span class="p">,</span> <span class="s1">&#39;Fri&#39;</span><span class="p">,</span> <span class="s1">&#39;Sat&#39;</span><span class="p">],</span>
        <span class="nx">A</span><span class="o">:</span> <span class="p">[</span><span class="s1">&#39;Sunday&#39;</span><span class="p">,</span> <span class="s1">&#39;Monday&#39;</span><span class="p">,</span> <span class="s1">&#39;Tuesday&#39;</span><span class="p">,</span> <span class="s1">&#39;Wednesday&#39;</span><span class="p">,</span> <span class="s1">&#39;Thursday&#39;</span><span class="p">,</span> <span class="s1">&#39;Friday&#39;</span><span class="p">,</span> <span class="s1">&#39;Saturday&#39;</span><span class="p">],</span>
        <span class="nx">b</span><span class="o">:</span> <span class="p">[</span><span class="s1">&#39;Jan&#39;</span><span class="p">,</span> <span class="s1">&#39;Feb&#39;</span><span class="p">,</span> <span class="s1">&#39;Mar&#39;</span><span class="p">,</span> <span class="s1">&#39;Apr&#39;</span><span class="p">,</span> <span class="s1">&#39;May&#39;</span><span class="p">,</span> <span class="s1">&#39;Jun&#39;</span><span class="p">,</span> <span class="s1">&#39;Jul&#39;</span><span class="p">,</span> <span class="s1">&#39;Aug&#39;</span><span class="p">,</span> <span class="s1">&#39;Sep&#39;</span><span class="p">,</span> <span class="s1">&#39;Oct&#39;</span><span class="p">,</span> <span class="s1">&#39;Nov&#39;</span><span class="p">,</span> <span class="s1">&#39;Dec&#39;</span><span class="p">],</span>
        <span class="nx">B</span><span class="o">:</span> <span class="p">[</span><span class="s1">&#39;January&#39;</span><span class="p">,</span> <span class="s1">&#39;February&#39;</span><span class="p">,</span> <span class="s1">&#39;March&#39;</span><span class="p">,</span> <span class="s1">&#39;April&#39;</span><span class="p">,</span> <span class="s1">&#39;May&#39;</span><span class="p">,</span> <span class="s1">&#39;June&#39;</span><span class="p">,</span> <span class="s1">&#39;July&#39;</span><span class="p">,</span> <span class="s1">&#39;August&#39;</span><span class="p">,</span> <span class="s1">&#39;September&#39;</span><span class="p">,</span> <span class="s1">&#39;October&#39;</span><span class="p">,</span> <span class="s1">&#39;November&#39;</span><span class="p">,</span> <span class="s1">&#39;December&#39;</span><span class="p">],</span>
        <span class="nx">c</span><span class="o">:</span> <span class="s1">&#39;%a %d %b %Y %T %Z&#39;</span><span class="p">,</span>
        <span class="nx">p</span><span class="o">:</span> <span class="p">[</span><span class="s1">&#39;AM&#39;</span><span class="p">,</span> <span class="s1">&#39;PM&#39;</span><span class="p">],</span>
        <span class="nx">P</span><span class="o">:</span> <span class="p">[</span><span class="s1">&#39;am&#39;</span><span class="p">,</span> <span class="s1">&#39;pm&#39;</span><span class="p">],</span>
        <span class="nx">r</span><span class="o">:</span> <span class="s1">&#39;%I:%M:%S %p&#39;</span><span class="p">,</span>
        <span class="nx">x</span><span class="o">:</span> <span class="s1">&#39;%d/%m/%y&#39;</span><span class="p">,</span>
        <span class="nx">X</span><span class="o">:</span> <span class="s1">&#39;%T&#39;</span>
 <span class="p">};</span>

 <span class="nx">YAHOO</span><span class="p">.</span><span class="nx">util</span><span class="p">.</span><span class="nx">DateLocale</span><span class="p">[</span><span class="s1">&#39;en&#39;</span><span class="p">]</span> <span class="o">=</span> <span class="nx">YAHOO</span><span class="p">.</span><span class="nx">lang</span><span class="p">.</span><span class="nx">merge</span><span class="p">(</span><span class="nx">YAHOO</span><span class="p">.</span><span class="nx">util</span><span class="p">.</span><span class="nx">DateLocale</span><span class="p">,</span> <span class="p">{});</span>

 <span class="nx">YAHOO</span><span class="p">.</span><span class="nx">util</span><span class="p">.</span><span class="nx">DateLocale</span><span class="p">[</span><span class="s1">&#39;en-US&#39;</span><span class="p">]</span> <span class="o">=</span> <span class="nx">YAHOO</span><span class="p">.</span><span class="nx">lang</span><span class="p">.</span><span class="nx">merge</span><span class="p">(</span><span class="nx">YAHOO</span><span class="p">.</span><span class="nx">util</span><span class="p">.</span><span class="nx">DateLocale</span><span class="p">[</span><span class="s1">&#39;en&#39;</span><span class="p">],</span> <span class="p">{</span>
        <span class="nx">c</span><span class="o">:</span> <span class="s1">&#39;%a %d %b %Y %I:%M:%S %p %Z&#39;</span><span class="p">,</span>
        <span class="nx">x</span><span class="o">:</span> <span class="s1">&#39;%m/%d/%Y&#39;</span><span class="p">,</span>
        <span class="nx">X</span><span class="o">:</span> <span class="s1">&#39;%I:%M:%S %p&#39;</span>
 <span class="p">});</span>

 <span class="nx">YAHOO</span><span class="p">.</span><span class="nx">util</span><span class="p">.</span><span class="nx">DateLocale</span><span class="p">[</span><span class="s1">&#39;en-GB&#39;</span><span class="p">]</span> <span class="o">=</span> <span class="nx">YAHOO</span><span class="p">.</span><span class="nx">lang</span><span class="p">.</span><span class="nx">merge</span><span class="p">(</span><span class="nx">YAHOO</span><span class="p">.</span><span class="nx">util</span><span class="p">.</span><span class="nx">DateLocale</span><span class="p">[</span><span class="s1">&#39;en&#39;</span><span class="p">],</span> <span class="p">{</span>
        <span class="nx">r</span><span class="o">:</span> <span class="s1">&#39;%l:%M:%S %P %Z&#39;</span>
 <span class="p">});</span>
 <span class="nx">YAHOO</span><span class="p">.</span><span class="nx">util</span><span class="p">.</span><span class="nx">DateLocale</span><span class="p">[</span><span class="s1">&#39;en-AU&#39;</span><span class="p">]</span> <span class="o">=</span> <span class="nx">YAHOO</span><span class="p">.</span><span class="nx">lang</span><span class="p">.</span><span class="nx">merge</span><span class="p">(</span><span class="nx">YAHOO</span><span class="p">.</span><span class="nx">util</span><span class="p">.</span><span class="nx">DateLocale</span><span class="p">[</span><span class="s1">&#39;en&#39;</span><span class="p">]);</span>

<span class="p">})();</span>
</pre></div>

                    </div>
			</div>
		</div>
		<div class="yui-b">
            <div class="nav">

                    <div id="moduleList" class="module">
                        <h4>Modules</h4>
                        <ul class="content">
                                <li class=""><a href="module_animation.html" title="animation">animation</a></li>
                                <li class=""><a href="module_autocomplete.html" title="autocomplete">autocomplete</a></li>
                                <li class=""><a href="module_button.html" title="button">button</a></li>
                                <li class=""><a href="module_calendar.html" title="calendar">calendar</a></li>
                                <li class=""><a href="module_carousel.html" title="carousel">carousel</a></li>
                                <li class=""><a href="module_charts.html" title="charts">charts</a></li>
                                <li class=""><a href="module_colorpicker.html" title="colorpicker">colorpicker</a></li>
                                <li class=""><a href="module_connection.html" title="connection">connection</a></li>
                                <li class=""><a href="module_container.html" title="container">container</a></li>
                                <li class=""><a href="module_cookie.html" title="cookie">cookie</a></li>
                                <li class="selected"><a href="module_datasource.html" title="datasource">datasource</a></li>
                                <li class=""><a href="module_datatable.html" title="datatable">datatable</a></li>
                                <li class=""><a href="module_datemath.html" title="datemath">datemath</a></li>
                                <li class=""><a href="module_dom.html" title="dom">dom</a></li>
                                <li class=""><a href="module_dragdrop.html" title="dragdrop">dragdrop</a></li>
                                <li class=""><a href="module_editor.html" title="editor">editor</a></li>
                                <li class=""><a href="module_element.html" title="element">element</a></li>
                                <li class=""><a href="module_element-delegate.html" title="element-delegate">element-delegate</a></li>
                                <li class=""><a href="module_event.html" title="event">event</a></li>
                                <li class=""><a href="module_event-delegate.html" title="event-delegate">event-delegate</a></li>
                                <li class=""><a href="module_event-mouseenter.html" title="event-mouseenter">event-mouseenter</a></li>
                                <li class=""><a href="module_event-simulate.html" title="event-simulate">event-simulate</a></li>
                                <li class=""><a href="module_get.html" title="get">get</a></li>
                                <li class=""><a href="module_history.html" title="history">history</a></li>
                                <li class=""><a href="module_imagecropper.html" title="imagecropper">imagecropper</a></li>
                                <li class=""><a href="module_imageloader.html" title="imageloader">imageloader</a></li>
                                <li class=""><a href="module_json.html" title="json">json</a></li>
                                <li class=""><a href="module_layout.html" title="layout">layout</a></li>
                                <li class=""><a href="module_logger.html" title="logger">logger</a></li>
                                <li class=""><a href="module_menu.html" title="menu">menu</a></li>
                                <li class=""><a href="module_paginator.html" title="paginator">paginator</a></li>
                                <li class=""><a href="module_profiler.html" title="profiler">profiler</a></li>
                                <li class=""><a href="module_profilerviewer.html" title="profilerviewer">profilerviewer</a></li>
                                <li class=""><a href="module_progressbar.html" title="progressbar">progressbar</a></li>
                                <li class=""><a href="module_resize.html" title="resize">resize</a></li>
                                <li class=""><a href="module_selector.html" title="selector">selector</a></li>
                                <li class=""><a href="module_slider.html" title="slider">slider</a></li>
                                <li class=""><a href="module_storage.html" title="Storage">Storage</a></li>
                                <li class=""><a href="module_stylesheet.html" title="stylesheet">stylesheet</a></li>
                                <li class=""><a href="module_swf.html" title="swf">swf</a></li>
                                <li class=""><a href="module_swfdetect.html" title="swfdetect">swfdetect</a></li>
                                <li class=""><a href="module_swfstore.html" title="swfstore">swfstore</a></li>
                                <li class=""><a href="module_tabview.html" title="tabview">tabview</a></li>
                                <li class=""><a href="module_treeview.html" title="treeview">treeview</a></li>
                                <li class=""><a href="module_uploader.html" title="uploader">uploader</a></li>
                                <li class=""><a href="module_yahoo.html" title="yahoo">yahoo</a></li>
                                <li class=""><a href="module_yuiloader.html" title="yuiloader">yuiloader</a></li>
                                <li class=""><a href="module_yuitest.html" title="yuitest">yuitest</a></li>
                        </ul>
                    </div>

                    <div id="classList" class="module">
                        <h4>Classes</h4>
                        <ul class="content">
                                <li class=""><a href="YAHOO.util.DataSource.html" title="YAHOO.util.DataSource">YAHOO.util.DataSource</a></li>
                                <li class=""><a href="YAHOO.util.DataSourceBase.html" title="YAHOO.util.DataSourceBase">YAHOO.util.DataSourceBase</a></li>
                                <li class=""><a href="YAHOO.util.Date.html" title="YAHOO.util.Date">YAHOO.util.Date</a></li>
                                <li class=""><a href="YAHOO.util.DateLocale.html" title="YAHOO.util.DateLocale">YAHOO.util.DateLocale</a></li>
                                <li class=""><a href="YAHOO.util.FunctionDataSource.html" title="YAHOO.util.FunctionDataSource">YAHOO.util.FunctionDataSource</a></li>
                                <li class=""><a href="YAHOO.util.LocalDataSource.html" title="YAHOO.util.LocalDataSource">YAHOO.util.LocalDataSource</a></li>
                                <li class=""><a href="YAHOO.util.Number.html" title="YAHOO.util.Number">YAHOO.util.Number</a></li>
                                <li class=""><a href="YAHOO.util.ScriptNodeDataSource.html" title="YAHOO.util.ScriptNodeDataSource">YAHOO.util.ScriptNodeDataSource</a></li>
                                <li class=""><a href="YAHOO.util.XHRDataSource.html" title="YAHOO.util.XHRDataSource">YAHOO.util.XHRDataSource</a></li>
                        </ul>
                    </div>

                    <div id="fileList" class="module">
                        <h4>Files</h4>
                        <ul class="content">        
                                <li class=""><a href="DataSource.js.html" title="DataSource.js">DataSource.js</a></li>
                                <li class="selected"><a href="Type.js.html" title="Type.js">Type.js</a></li>
                        </ul>
                    </div>





            </div>
		</div>
	</div>
	<div id="ft">
        <hr />
        Copyright &copy; 2011 Yahoo! Inc. All rights reserved.
	</div>
</div>
<script type="text/javascript">

    var ALL_YUI_PROPS = [{"access": "private", "host": "YAHOO.util.DataSourceBase", "name": "_aCache", "url": "YAHOO.util.DataSourceBase.html#property__aCache", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "addToCache", "url": "YAHOO.util.DataSourceBase.html#method_addToCache", "type": "method"}, {"access": "private", "host": "YAHOO.util.DataSourceBase", "name": "_aIntervals", "url": "YAHOO.util.DataSourceBase.html#property__aIntervals", "type": "property"}, {"access": "", "host": "YAHOO.util.ScriptNodeDataSource", "name": "asyncMode", "url": "YAHOO.util.ScriptNodeDataSource.html#property_asyncMode", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "cacheFlushEvent", "url": "YAHOO.util.DataSourceBase.html#event_cacheFlushEvent", "type": "event"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "cacheRequestEvent", "url": "YAHOO.util.DataSourceBase.html#event_cacheRequestEvent", "type": "event"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "cacheResponseEvent", "url": "YAHOO.util.DataSourceBase.html#event_cacheResponseEvent", "type": "event"}, {"access": "", "host": "YAHOO.util.ScriptNodeDataSource", "name": "callbacks", "url": "YAHOO.util.ScriptNodeDataSource.html#property_callbacks", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "clearAllIntervals", "url": "YAHOO.util.DataSourceBase.html#method_clearAllIntervals", "type": "method"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "clearInterval", "url": "YAHOO.util.DataSourceBase.html#method_clearInterval", "type": "method"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "cloneBeforeCaching", "url": "YAHOO.util.DataSourceBase.html#property_cloneBeforeCaching", "type": "property"}, {"access": "", "host": "YAHOO.util.XHRDataSource", "name": "connMethodPost", "url": "YAHOO.util.XHRDataSource.html#property_connMethodPost", "type": "property"}, {"access": "", "host": "YAHOO.util.XHRDataSource", "name": "connMgr", "url": "YAHOO.util.XHRDataSource.html#property_connMgr", "type": "property"}, {"access": "", "host": "YAHOO.util.XHRDataSource", "name": "connTimeout", "url": "YAHOO.util.XHRDataSource.html#property_connTimeout", "type": "property"}, {"access": "", "host": "YAHOO.util.XHRDataSource", "name": "connXhrMode", "url": "YAHOO.util.XHRDataSource.html#property_connXhrMode", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "dataErrorEvent", "url": "YAHOO.util.DataSourceBase.html#event_dataErrorEvent", "type": "event"}, {"access": "private", "host": "YAHOO.util.DataSourceBase", "name": "DataSourceBase._cloneObject", "url": "YAHOO.util.DataSourceBase.html#method_DataSourceBase._cloneObject", "type": "method"}, {"access": "private", "host": "YAHOO.util.DataSourceBase", "name": "DataSourceBase._nIndex", "url": "YAHOO.util.DataSourceBase.html#property_DataSourceBase._nIndex", "type": "property"}, {"access": "private", "host": "YAHOO.util.DataSourceBase", "name": "DataSourceBase._nTransactionId", "url": "YAHOO.util.DataSourceBase.html#property_DataSourceBase._nTransactionId", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "DataSourceBase.parseDate", "url": "YAHOO.util.DataSourceBase.html#method_DataSourceBase.parseDate", "type": "method"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "DataSourceBase.parseNumber", "url": "YAHOO.util.DataSourceBase.html#method_DataSourceBase.parseNumber", "type": "method"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "DataSourceBase.parseString", "url": "YAHOO.util.DataSourceBase.html#method_DataSourceBase.parseString", "type": "method"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "DataSource.Parser", "url": "YAHOO.util.DataSourceBase.html#property_DataSource.Parser", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "dataType", "url": "YAHOO.util.DataSourceBase.html#property_dataType", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "doBeforeCallback", "url": "YAHOO.util.DataSourceBase.html#method_doBeforeCallback", "type": "method"}, {"access": "", "host": "YAHOO.util.ScriptNodeDataSource", "name": "doBeforeGetScriptNode", "url": "YAHOO.util.ScriptNodeDataSource.html#method_doBeforeGetScriptNode", "type": "method"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "doBeforeParseData", "url": "YAHOO.util.DataSourceBase.html#method_doBeforeParseData", "type": "method"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "ERROR_DATAINVALID", "url": "YAHOO.util.DataSourceBase.html#property_ERROR_DATAINVALID", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "ERROR_DATANULL", "url": "YAHOO.util.DataSourceBase.html#property_ERROR_DATANULL", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "flushCache", "url": "YAHOO.util.DataSourceBase.html#method_flushCache", "type": "method"}, {"access": "", "host": "YAHOO.util.Number", "name": "format", "url": "YAHOO.util.Number.html#method_format", "type": "method"}, {"access": "", "host": "YAHOO.util.Date", "name": "format", "url": "YAHOO.util.Date.html#method_format", "type": "method"}, {"access": "", "host": "YAHOO.util.ScriptNodeDataSource", "name": "generateRequestCallback", "url": "YAHOO.util.ScriptNodeDataSource.html#method_generateRequestCallback", "type": "method"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "getCachedResponse", "url": "YAHOO.util.DataSourceBase.html#method_getCachedResponse", "type": "method"}, {"access": "private", "host": "YAHOO.util.DataSourceBase", "name": "_getLocationValue", "url": "YAHOO.util.DataSourceBase.html#method__getLocationValue", "type": "method"}, {"access": "", "host": "YAHOO.util.ScriptNodeDataSource", "name": "getUtility", "url": "YAHOO.util.ScriptNodeDataSource.html#property_getUtility", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "handleResponse", "url": "YAHOO.util.DataSourceBase.html#method_handleResponse", "type": "method"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "isCacheHit", "url": "YAHOO.util.DataSourceBase.html#method_isCacheHit", "type": "method"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "issueCallback", "url": "YAHOO.util.DataSourceBase.html#method_issueCallback", "type": "method"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "liveData", "url": "YAHOO.util.DataSourceBase.html#property_liveData", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "makeConnection", "url": "YAHOO.util.DataSourceBase.html#method_makeConnection", "type": "method"}, {"access": "", "host": "YAHOO.util.FunctionDataSource", "name": "makeConnection", "url": "YAHOO.util.FunctionDataSource.html#method_makeConnection", "type": "method"}, {"access": "", "host": "YAHOO.util.ScriptNodeDataSource", "name": "makeConnection", "url": "YAHOO.util.ScriptNodeDataSource.html#method_makeConnection", "type": "method"}, {"access": "", "host": "YAHOO.util.XHRDataSource", "name": "makeConnection", "url": "YAHOO.util.XHRDataSource.html#method_makeConnection", "type": "method"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "maxCacheEntries", "url": "YAHOO.util.DataSourceBase.html#property_maxCacheEntries", "type": "property"}, {"access": "private", "host": "YAHOO.util.ScriptNodeDataSource", "name": "_nId", "url": "YAHOO.util.ScriptNodeDataSource.html#property__nId", "type": "property"}, {"access": "private", "host": "YAHOO.util.ScriptNodeDataSource", "name": "_nPending", "url": "YAHOO.util.ScriptNodeDataSource.html#property__nPending", "type": "property"}, {"access": "", "host": "YAHOO.util.Number", "name": "Number.format._applyFormat", "url": "YAHOO.util.Number.html#method_Number.format._applyFormat", "type": "method"}, {"access": "", "host": "YAHOO.util.Number", "name": "Number.format.defaults", "url": "YAHOO.util.Number.html#property_Number.format.defaults", "type": "property"}, {"access": "private", "host": "YAHOO.util.DataSourceBase", "name": "_oQueue", "url": "YAHOO.util.DataSourceBase.html#property__oQueue", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "parseArrayData", "url": "YAHOO.util.DataSourceBase.html#method_parseArrayData", "type": "method"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "parseData", "url": "YAHOO.util.DataSourceBase.html#method_parseData", "type": "method"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "parseHTMLTableData", "url": "YAHOO.util.DataSourceBase.html#method_parseHTMLTableData", "type": "method"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "parseJSONArgs", "url": "YAHOO.util.DataSourceBase.html#property_parseJSONArgs", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "parseJSONData", "url": "YAHOO.util.DataSourceBase.html#method_parseJSONData", "type": "method"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "parseTextData", "url": "YAHOO.util.DataSourceBase.html#method_parseTextData", "type": "method"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "parseXMLData", "url": "YAHOO.util.DataSourceBase.html#method_parseXMLData", "type": "method"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "parseXMLResult", "url": "YAHOO.util.DataSourceBase.html#method_parseXMLResult", "type": "method"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "requestEvent", "url": "YAHOO.util.DataSourceBase.html#event_requestEvent", "type": "event"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "responseCacheEvent", "url": "YAHOO.util.DataSourceBase.html#event_responseCacheEvent", "type": "event"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "responseEvent", "url": "YAHOO.util.DataSourceBase.html#event_responseEvent", "type": "event"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "responseParseEvent", "url": "YAHOO.util.DataSourceBase.html#event_responseParseEvent", "type": "event"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "responseSchema", "url": "YAHOO.util.DataSourceBase.html#property_responseSchema", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "responseType", "url": "YAHOO.util.DataSourceBase.html#property_responseType", "type": "property"}, {"access": "", "host": "YAHOO.util.FunctionDataSource", "name": "scope", "url": "YAHOO.util.FunctionDataSource.html#property_scope", "type": "property"}, {"access": "", "host": "YAHOO.util.ScriptNodeDataSource", "name": "scriptCallbackParam", "url": "YAHOO.util.ScriptNodeDataSource.html#property_scriptCallbackParam", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "sendRequest", "url": "YAHOO.util.DataSourceBase.html#method_sendRequest", "type": "method"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "setInterval", "url": "YAHOO.util.DataSourceBase.html#method_setInterval", "type": "method"}, {"access": "private", "host": "YAHOO.util.DataSourceBase", "name": "_sName", "url": "YAHOO.util.DataSourceBase.html#property__sName", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "toString", "url": "YAHOO.util.DataSourceBase.html#method_toString", "type": "method"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "TYPE_HTMLTABLE", "url": "YAHOO.util.DataSourceBase.html#property_TYPE_HTMLTABLE", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "TYPE_JSARRAY", "url": "YAHOO.util.DataSourceBase.html#property_TYPE_JSARRAY", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "TYPE_JSFUNCTION", "url": "YAHOO.util.DataSourceBase.html#property_TYPE_JSFUNCTION", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "TYPE_JSON", "url": "YAHOO.util.DataSourceBase.html#property_TYPE_JSON", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "TYPE_LOCAL", "url": "YAHOO.util.DataSourceBase.html#property_TYPE_LOCAL", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "TYPE_SCRIPTNODE", "url": "YAHOO.util.DataSourceBase.html#property_TYPE_SCRIPTNODE", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "TYPE_TEXT", "url": "YAHOO.util.DataSourceBase.html#property_TYPE_TEXT", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "TYPE_UNKNOWN", "url": "YAHOO.util.DataSourceBase.html#property_TYPE_UNKNOWN", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "TYPE_XHR", "url": "YAHOO.util.DataSourceBase.html#property_TYPE_XHR", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "TYPE_XML", "url": "YAHOO.util.DataSourceBase.html#property_TYPE_XML", "type": "property"}, {"access": "", "host": "YAHOO.util.DataSourceBase", "name": "useXPath", "url": "YAHOO.util.DataSourceBase.html#property_useXPath", "type": "property"}, {"access": "private", "host": "YAHOO.util.XHRDataSource", "name": "_xhrCallback", "url": "YAHOO.util.XHRDataSource.html#property__xhrCallback", "type": "property"}, {"access": "private", "host": "YAHOO.util.XHRDataSource", "name": "_xhrFailure", "url": "YAHOO.util.XHRDataSource.html#method__xhrFailure", "type": "method"}, {"access": "private", "host": "YAHOO.util.XHRDataSource", "name": "_xhrSuccess", "url": "YAHOO.util.XHRDataSource.html#method__xhrSuccess", "type": "method"}];
</script>
</body>
</html>
